package sketch.specs;

import java.util.Collection;
import java.util.LinkedHashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;

import org.eclipse.jdt.core.dom.Block;

import sketch.ast.ASTUtils;
import sketch.specs.annotation.IdentifierBlock;
import sketch.util.Checker;

public class SketchedIdentifierBlock extends SketchedBlock {

	public final String identifier;
	
	public static final String COMMENT_REPRESENTATION = IdentifierBlock.value();
	
	public SketchedIdentifierBlock(Block realBlock, String identifier) {
		super(realBlock);
		Checker.checkNull(identifier, "The identifier could not be null.");
		this.identifier = identifier;
	}

	@Override
	protected List<Block> replicate() {
		List<Block> retBlocks = new LinkedList<Block>();
		retBlocks.add(this.realBlock);
		return retBlocks;
	}

	@Override
	protected SketchedBlock newInstance(Block block) {
		return new SketchedIdentifierBlock(this.realBlock, this.identifier);
	}
}
